import React ,{useEffect,useState}from 'react';
import { useParams } from 'react-router-dom';
import { Button, } from 'antd';
import * as service from "../../../api/index"
import "./ZixunXinxi.scss"
interface props{

}
function ZixunXinxi(props:props) {

    var params=useParams()
    var [list2, setlist]:any = useState();
    var xiangqing= async()=>{
     var res= await service.Zixun_xiangqig({id:params.id})
     console.log(res.data)
     setlist(res.data)
    }
    useEffect(()=>{
        console.log("77")
       console.log(params)
       xiangqing()
    },[])

    return (
        <div className='ZixunXinxi'>
             <div className='header'>
                <p>  办事指南评价详情</p>
                <div className='header_right'>
                    <Button type="primary" >回复</Button>
                    <Button >关闭</Button>
                </div>
            </div>
            
              <div className='from'>
                <div className='from_header'>资讯信息</div>
             <div className='hang'>       <div className='left'>受理部门</div><div className='right'>{list2&&list2.department}</div></div>
                 <div className='hang'>   <div className='left'>类型</div><div className='right'>{list2&&list2.type}</div></div>
                   <div className='hang'> <div className='left'>标题</div><div className='right'>{list2&&list2.headline }</div></div>
                   <div className='hang'> <div className='left'>咨询内容</div><div className='right'>{list2&&list2.content     }</div></div>
                 <div className='hang'>
                        <div className='left'>联系人</div><div className='right'>{list2&&list2.name       }</div>
     
                 </div>
                   <div className='hang'> <div className='left'>联系电话</div><div className='right'> {list2&&list2.phone       }</div></div>
                   <div className='hang'> <div className='left'>提出时间</div><div className='right'>{list2&&list2.time        }</div></div >
                   <div className='hang'> <div className='left'>回复状态</div><div className='right'>{list2&&list2.department+"未受理"}</div></div>
                
                   
              </div>
        </div>
    );
}

export default ZixunXinxi;